package ModelLayer;
import java.util.ArrayList;

/**
 * A collection of attributes to describe a DVD
 * 
 * @author (Erni Kristensen)
 * @version (17-04-2013)
 */
public class Dvd
{
    //
    private long id;
    private String title;
    private String artist;
    private String releaseDate;
    private ArrayList<Eksemplar> eksemplar;
    
    public Dvd(long id, String title, String artist, String releaseDate)
    {
        setId(id);
        setTitle(title);
        setArtist(artist);
        setReleaseDate(releaseDate);
        eksemplar = new ArrayList<Eksemplar>();
    }
    
    public void setId(long id)
    {
        this.id = id;
    }
    
    public void setTitle(String title)
    {
        this.title = title;
    }
    
    public void setArtist(String artist)
    {
        this.artist = artist;
    }
    
    public void setReleaseDate(String releaseDate)
    {
        this.releaseDate = releaseDate;
    }
    
    public long getId()
    {
        return id;
    }
    
    public String getTitle()
    {
        return title;
    }
    
    public String getArtist()
    {
        return artist;
    }
    
    public String getReleaseDate()
    {
        return releaseDate;
    }
    
    public void addEksemplar(Eksemplar oneEksemplar)
    {
        eksemplar.add(oneEksemplar);
    }
    
    public ArrayList listAllCopies()
    {
        return eksemplar;
    }
}
